package com.ct.mappers;

import com.ct.entity.po.Travel;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 行程表 数据库操作接口
 */
@Mapper
public interface ScheduleMapper<T, P> extends BaseMapper<T, P> {

    /**
     * 根据ScheduleId更新
     */
    Integer updateByScheduleId(@Param("bean") T t, @Param("scheduleId") Integer scheduleId);

    /**
     * 根据ScheduleId删除
     */
    Integer deleteByScheduleId(@Param("scheduleId") Integer scheduleId);

    /**
     * 根据ScheduleId获取对象
     */
    T selectByScheduleId(@Param("scheduleId") Integer scheduleId);

    List<Travel> selectByTravelId(@Param("travelId") Integer travelId);
}
